package com.ylx.code.controller;

import com.ylx.code.service.MarkInfoService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.AllArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * ClassName: HelloController <br/>
 * Description: <br/>
 * date: 2023/10/23 15:46<br/>
 *
 * @author yanglixin<br />
 */
@Slf4j
@RestController
@AllArgsConstructor
@Api(tags = "Hello接口")
@RequestMapping("/hello")
public class HelloController {

    private final MarkInfoService markInfoService;

    @GetMapping("/hello")
    @ApiOperation("测试成功")
    public Object addCustomView() {
        return "SUCCESS";
    }

    @GetMapping("/success")
    @ApiOperation("测试数据库")
    public Object success() {
        return markInfoService.list();
    }
}
